package dbtools.test;

import dbtools.structures.DBFieldDatetime;
import dbtools.structures.DBFieldInt;
import dbtools.structures.DBFieldText;
import dbtools.structures.DBKeyElement;
import dbtools.structures.DBTable;
import dbtools.structures.DBUniqueKey;

public class Customers extends DBTable{

	private static final long serialVersionUID = 1L;
	
	public DBFieldInt cust_no = new DBFieldInt();
	public DBFieldText cust_name = new DBFieldText(30);
	public DBFieldDatetime last_update = new DBFieldDatetime();
	
	public DBUniqueKey key = new DBUniqueKey("custs_key1",new DBKeyElement(cust_no,ASC));
	
	public static Object[] buildKey(Integer custNo){
		return new Object[]{custNo};
	}
	
	@Override
	public String getTableName() {
		return "customers";
	}

}
